/*
 * @file    :task_monitor.h
 * @author  :LingFengLu
 * @date    :2023-06-08
 */

#ifndef _TASK_MONITOR_H_
#define _TASK_MONITOR_H_
#include "global.h"
#include "devos.h"
//Constant definition    宏定义


//Type definition    类型定义
typedef enum
{
    TASK_MONITOR_PARAM_DATE_TIME = 0,
    TASK_MONITOR_PARAM_HISTORY,
    TASK_MONITOR_PARAM_EVENT,
    TASK_MONITOR_PARAM_BUSY,
    TASK_MONITOR_PARAM_STATUS,
    TASK_MONITOR_PARAM_POWER,
    TASK_MONITOR_PARAM_OPTIONAL_STATUS,
    TASK_MONITOR_PARAM_HISTORIES_FULL,
    TASK_MONITOR_PARAM_HISTORIES,
    TASK_MONITOR_PARAM_START_TIME,
    TASK_MONITOR_PARAM_RUNNING_TIME,
    TASK_MONITOR_PARAM_ELAPSED_TIME,
    TASK_MONITOR_PARAM_UPDATE_SWITCH,
    // TASK_MONITOR_PARAM_HISTORY_HEAD_FLAG,
    TASK_MONITOR_PARAM_UPDATE_BROADCAST,
    TASK_MONITOR_COUNT_PARAM
} task_monitor_param;

//Function declaration    函数申明
void TaskMonitor_Init
(
	devos_task_handle t_TaskHandle
);
void TaskMonitor_Process
(
	devos_task_handle t_TaskHandle
);
uint TaskMonitor_SetConfig
(
	uint ui_Parameter,
	const uint8 *u8p_Value,
	uint ui_Length
);
uint TaskMonitor_GetConfig
(
	uint ui_Parameter,
	uint8 *u8p_Value,
	uint *uip_Length
);
uint8 TaskMonitor_SensorIndex(void);
uint TaskMonitor_SetEvent
( 
	uint8 u8_Type, 
	uint8 u8_Value
);
uint TaskMonitor_SetRemoteEvent
( 
    sint32 s32_DateTime, 
    uint8 u8_Type, 
    uint16 u16_Value 
);
uint TaskMonitor_SetEventLog
( 
	uint16 u16_Type
);
uint TaskMonitor_Reset(void);
//Golbal variable declaration   全局变量申明










#endif

